package com.lancoo.lancooimageloader;

import android.graphics.drawable.Drawable;

/**
 * Author: Andecy
 * Time: 2017/5/22
 * Email: andecy@foxmail.com
 * Description: TODO
 */

public interface LancooImageCallback {

    void onSuccess(Drawable result);

    void onError(Throwable ex, boolean isOnCallback);

    void onCancelled(CancelledException cex);

    void onFinished();

    public static class CancelledException extends RuntimeException {
        public CancelledException(String detailMessage) {
            super(detailMessage);
        }
    }
}
